//
//  GLAFRequest.h
//  太平人寿 - 1
//
//  Created by rimi on 14-6-9.
//  Copyright (c) 2014年 rimi. All rights reserved.
//

#import <Foundation/Foundation.h>

@interface GLAFRequest : NSObject

//普通请求
+ (void)startRequest:(NSString *)urlString
           paramsDic:(NSDictionary *)paramsDic
       handleSuccess:(void(^)(id sta,NSDictionary * paramsDic)) handleSuccess;
+ (void)startRequest:(NSString *)urlString
           paramsDic:(NSDictionary *)paramsDic
       handleSuccess:(void(^)(id sta,NSDictionary * paramsDic)) handleSuccess
         netWorkFail:(void(^)(NSDictionary * paramsDic))netWorkFail;
+ (void)startRequest:(NSString *)urlString
           paramsDic:(NSDictionary *)paramsDic
       handleSuccess:(void(^)(id sta,NSDictionary * paramsDic)) handleSuccess
           doFinally:(void(^)(NSDictionary * paramsDic)) doFinally;//是否成功都要做的一件事
//是否有菊花提示
+ (void)startRequest:(NSString *)urlString
           paramsDic:(NSDictionary *)paramsDic
      defaultdialog :(BOOL)defaultdialog
       handleSuccess:(void(^)(id sta,NSDictionary * paramsDic)) handleSuccess
           doFinally:(void(^)(NSDictionary * paramsDic)) doFinally;
+ (void)startRequest:(NSString *)urlString
      defaultdialog :(BOOL)defaultdialog
           paramsDic:(NSDictionary *)paramsDic
       handleSuccess:(void(^)(id sta,NSDictionary * paramsDic)) handleSuccess
         netWorkFail:(void(^)(NSDictionary * paramsDic))netWorkFail;

+ (void)startRequest:(NSString *)urlString
           paramsDic:(NSDictionary *)paramsDic
      defaultdialog :(BOOL)defaultdialog
       handleSuccess:(void(^)(id sta,NSDictionary * paramsDic)) handleSuccess
         netWorkFail:(void(^)(NSDictionary * paramsDic))netWorkFail
           doFinally:(void(^)(NSDictionary * paramsDic)) doFinally;

//取消菊花
+ (void)startRequest:(NSString *)urlString
             istouch:(BOOL)istouch
           paramsDic:(NSDictionary *)paramsDic
       handleSuccess:(void(^)(id sta,NSDictionary * paramsDic)) handleSuccess
           doFinally:(void(^)(NSDictionary * paramsDic)) doFinally;
//上传
//有进度
+ (void)startFileRequest:(NSString *)urlString
                    time:(NSInteger)time
               paramsDic:(NSDictionary *)paramsDic
                  picDic:(NSDictionary *)picDic
           handleSuccess:(void(^)(id sta,NSDictionary * paramsDic)) handleSuccess
                progress:(void(^)(id progressNum)) progress
             netWorkFail:(void(^)(NSDictionary * paramsDic))netWorkFail;
//无进度
+ (void)startFileRequest:(NSString *)urlString
                    time:(NSInteger)time
                 isTouch:(BOOL)isTouch
               paramsDic:(NSDictionary *)paramsDic
           defaultdialog:(BOOL)defaultdialog
                  picDic:(NSDictionary *)picDic
           handleSuccess:(void(^)(id sta,NSDictionary * paramsDic)) handleSuccess
             netWorkFail:(void(^)(NSDictionary * paramsDic))netWorkFail;

+ (void)startRequest:(NSString *)urlString
      defaultdialog :(BOOL)defaultdialog
  defaultNetworkfail:(BOOL)defaultNetworkfail
           paramsDic:(NSDictionary *)paramsDic
       handleSuccess:(void(^)(id sta,NSDictionary * paramsDic)) handleSuccess
         netWorkFail:(void(^)(NSDictionary * paramsDic))netWorkFail;

+ (void)startRequest:(NSString *)urlString
           paramsDic:(NSDictionary *)paramsDic
      defaultdialog :(BOOL)defaultdialog
 defaultNetworkfail :(BOOL)defaultNetworkfail
       handleSuccess:(void(^)(id sta,NSDictionary * paramsDic)) handleSuccess
           doFinally:(void(^)(NSDictionary * paramsDic)) doFinally;


//是否是需要get请求
+ (void)startRequest:(NSString *)urlString
           paramsDic:(NSDictionary *)paramsDic
      defaultdialog :(BOOL)defaultdialog
              ispost:(BOOL)post
       handleSuccess:(void(^)(id sta,NSDictionary * paramsDic)) handleSuccess
           doFinally:(void(^)(NSDictionary * paramsDic)) doFinally;

@end
